<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>函数参数默认值</title>
    <script>
        function add(a , b = 1) {
            return a + b;
        }
        // 传一个参数
        console.log(add(10));
    </script>
</head>
<body>

</body>
</html>